<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<meta http-equiv="Content-type" content="text/html; charset=utf-8" />

	<title>Livraria Online</title>
	<link rel="stylesheet" href="css/cupertino/jquery-ui-1.10.3.custom.css" type="text/css" media="screen, projection" />
	
	<script language="javascript" type="text/javascript" src="js/jquery-1.10.2.min.js"></script>
    <script language="javascript" type="text/javascript" src="js/jquery-ui-1.10.3.custom.js"></script>
    
    <link rel="stylesheet" href="css/estilo.css">
    
    <script language="javascript" type="text/javascript">
	    $(function() {
			$( "#menu" ).menu();
			
			$("#btCadastrar").click(function(){
				window.location.assign("/Livraria/cadastroUsuario.jsp");
			});
		});
    </script>
    <style>
		* {
			margin: 0px auto;
		}
		#tbLogin {
			margin-top: 20%;
			border: 1px solid #CCC;
			padding: 15px;
		}]
		
		.ui-menu { width: 150px; }
		
	</style>
</head>

<body>
	<form action="/Livraria/login" method="post">
		<table id="tbLogin">
			<c:if test="${not empty erro}">
				<tr>
					<td colspan="2">
						<div style="color: red;">
							<c:out value="${erro}"></c:out>
						</div>
					</td>
				</tr>
			</c:if>
			<tr>
				<td>Email: </td>
				<td><input type="text" name="email"/> </td>
			</tr>
			<tr>
				<td>Senha: </td>
				<td><input type="password" name="senha"/> </td>
			</tr>
			<tr>
				<td colspan="2"><input type="submit" value="Login"/></td>
			</tr>
			<tr>
				<td colspan="2"><input type="button" id="btCadastrar" value="Cadastrar" /></td>
			</tr>
		</table>
	</form>
<body>

</body>
</html>